package io.renren.modules.back.controller;

import io.renren.common.utils.R;
import io.renren.modules.back.entity.BrandEntity;
import io.renren.modules.back.service.BrandService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

/**
 * 品牌接口
 *
 * @author zzh
 * @email 862583291@qq.com
 * @date 2019年3月10日 上午10:40:10
 */
@RestController
@RequestMapping("/back/brand")
public class BrandController {

    @Autowired
    private BrandService brandService;

    /**
     * 查看所有列表
     */
    @RequestMapping("/queryAll")
    public R queryAll(@RequestParam Map<String, Object> params) {

        List<BrandEntity> list = brandService.list();

        return R.ok().put("data", list);
    }
}
